let storage = {
    get(key) {
        let value = localStorage.getItem(key)
        if (value && value != 'undefined') {
            return JSON.parse(value)
        }
        return false
    },
    set(key, value) {
        localStorage.setItem(key, JSON.stringify(value))
    },
    clear(key) {
        localStorage.removeItem(key)
    },
    clearAll() {
        localStorage.clear()
    }
}


export default storage
